Because of the thinner cable from the wii u digitzer... ?

No the adafruit connector will not hold the thin fpc in place unless you put something underneath.xouliox wrote: ↑Sun Jun 17, 2018 1:39 amSo i cant combine ar1100 with this https://www.adafruit.com/product/334
Because of the thinner cable from the wii u digitzer... ?![]()
Here is the source code
Code: Select all
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.IO.Ports;
using System.IO;
using System.Diagnostics;
using System.Runtime.InteropServices;
namespace BATTMON
{
public partial class Form1 : Form
{
private bool shutdown = false;
public Form1()
{
InitializeComponent();
//serialPort1.Open();
serialPort1.DataReceived += serialPort1_DataReceived;
try
{
serialPort1.Open();
}
catch (IOException )
{
//Console.WriteLine(ex);
}
}
private void serialPort1_DataReceived(object sender, SerialDataReceivedEventArgs e)
{
string Teensy_Data = serialPort1.ReadLine();
this.BeginInvoke(new LineReceivedEvent(LineReceived), Teensy_Data);
}
private delegate void LineReceivedEvent(string Teensy_Data);
private void LineReceived(string Teensy_Data)
{
int input_reading;
input_reading = int.Parse(Teensy_Data);
double vcc;
double cpp;
double ten;
cpp = (((input_reading - 157.00) / (210.00 - 157.00)) * 100);
vcc = input_reading * (5.1 / 255.0)*2;
ten = input_reading;
string Vol = Convert.ToString(vcc);
string Cap = Convert.ToString(cpp);
string Ten = Convert.ToString(ten);
try
{
string Vol2dec = Vol.Substring(0, 3);
label2.Text = Vol2dec;
Single voltage = 0;
Single.TryParse(Vol2dec, out voltage);
if (shutdown == false)
{
if (voltage < 6.2) // 6.4 minimum to start shutdown if only LESS then 6.2
{
System.Diagnostics.Process.Start("shutdown", "/s /t 60");//.WaitForExit(60);
timer1.Enabled = true;
shutdown = true;
progressBar1.Visible = true;
button1.Visible = true;
label1.Visible = false;
groupBox1.Visible = false;
}
}
}
catch
{
label2.Text = "...";
}
try
{
string Cap2dec= Cap.Substring(0, 2);
label1.Text = Cap2dec;
}
catch
{
//label1.Text = "...";
}
try
{
string Ten2dec = Ten.Substring(0, 3);
label3.Text = Ten2dec;
}
catch
{
label3.Text = "...";
}
}
private void Form1_Load(object sender, EventArgs e)
{
}
private void Form1_SizeChanged(object sender, EventArgs e)
{
if (this.WindowState == FormWindowState.Minimized)
{
notifyIcon1.Visible = true;
ShowInTaskbar = false;
}
else
{
notifyIcon1.Visible = false;
}
}
private void notifyIcon1_MouseClick(object sender, MouseEventArgs e)
{
this.WindowState = FormWindowState.Normal;
ShowInTaskbar = true;
}
private void button1_Click(object sender, EventArgs e)
{
Process.Start("shutdown", "/a");
timer1.Enabled = false;
progressBar1.Visible = false;
button1.Visible = false;
}
private void timer1_Tick(object sender, EventArgs e)
{
progressBar1.Increment(1);
//label4.Text = progressBar1.Value.ToString()+" s";
}
}
}
Thank you friendbanjokazooie wrote: ↑Mon Jul 23, 2018 11:33 amHere is the source codeCode: Select all
using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.IO.Ports;using System.IO;using System.Diagnostics;using System.Runtime.InteropServices; namespace BATTMON{ public partial class Form1 : Form { private bool shutdown = false; public Form1() { InitializeComponent(); //serialPort1.Open(); serialPort1.DataReceived += serialPort1_DataReceived; try { serialPort1.Open(); } catch (IOException ) { //Console.WriteLine(ex); } } private void serialPort1_DataReceived(object sender, SerialDataReceivedEventArgs e) { string Teensy_Data = serialPort1.ReadLine(); this.BeginInvoke(new LineReceivedEvent(LineReceived), Teensy_Data); } private delegate void LineReceivedEvent(string Teensy_Data); private void LineReceived(string Teensy_Data) { int input_reading; input_reading = int.Parse(Teensy_Data); double vcc; double cpp; double ten; cpp = (((input_reading - 157.00) / (210.00 - 157.00)) * 100); vcc = input_reading * (5.1 / 255.0)*2; ten = input_reading; string Vol = Convert.ToString(vcc); string Cap = Convert.ToString(cpp); string Ten = Convert.ToString(ten); try { string Vol2dec = Vol.Substring(0, 3); label2.Text = Vol2dec; Single voltage = 0; Single.TryParse(Vol2dec, out voltage); if (shutdown == false) { if (voltage < 6.2) // 6.4 minimum to start shutdown if only LESS then 6.2 { System.Diagnostics.Process.Start("shutdown", "/s /t 60");//.WaitForExit(60); timer1.Enabled = true; shutdown = true; progressBar1.Visible = true; button1.Visible = true; label1.Visible = false; groupBox1.Visible = false; } } } catch { label2.Text = "..."; } try { string Cap2dec= Cap.Substring(0, 2); label1.Text = Cap2dec; } catch { //label1.Text = "..."; } try { string Ten2dec = Ten.Substring(0, 3); label3.Text = Ten2dec; } catch { label3.Text = "..."; } } private void Form1_Load(object sender, EventArgs e) { } private void Form1_SizeChanged(object sender, EventArgs e) { if (this.WindowState == FormWindowState.Minimized) { notifyIcon1.Visible = true; ShowInTaskbar = false; } else { notifyIcon1.Visible = false; } } private void notifyIcon1_MouseClick(object sender, MouseEventArgs e) { this.WindowState = FormWindowState.Normal; ShowInTaskbar = true; } private void button1_Click(object sender, EventArgs e) { Process.Start("shutdown", "/a"); timer1.Enabled = false; progressBar1.Visible = false; button1.Visible = false; } private void timer1_Tick(object sender, EventArgs e) { progressBar1.Increment(1); //label4.Text = progressBar1.Value.ToString()+" s"; } }}
Better stick to the silkscreen on the ar1100 and cross check the connection with the build in connector. P.s under win 10 the touch need special drivers to run properly in digitizer mode
You need to set up bios on compustick to auto power up when voltage is supplied when you press the button attached to pololu.
Users browsing this forum: No registered users and 1 guest