arduino

Receive and send data from arduino to c# and vice versa

不羁岁月 提交于 2019-12-11 09:18:14
问题 first of all I started using c# yesterday morning so I apologize for potential numb questions. So far I wrote the following code. I'm able to send data from c# to arduino which seems to be working fine. Now i would like to receive data from arduino, through serial.print, at the same time and display it in a box (ListBox?). How could add this to the code? I would be thankful for any input, tips and ideas. namespace WindowsFormsApplication1 { public partial class Form1 : Form { public Form1() {

Arduino-like Makefile with dependencies…?

十年热恋 提交于 2019-12-11 09:14:47
问题 I am currently trying to develop C libraries and project templates for the STM8 microcontroller using the SDCC OS compiler. My target is a (nearly) NOOB-compatible setup similar to Arduino - but with make+shellscripts instead of an IDE (there are limits to my ambition...) Currently I am struggling with make to auto-detect dependencies. In Arduino the user only includes the relevant headers, e.g. "#include LCD-lib", and the build mechanism automatically detects dependency and links the

C# access denied when trying to access communications port?

戏子无情 提交于 2019-12-11 08:56:43
问题 I'm trying to make a simple Windows Form Application in Visual Studios that will allow me to control the brightness setting of an LED strip hooked up to an Arduino. The programming inside the Arduino is already well and done, but the C# programming is what's giving me trouble. When trying to send strings of information through the port, I receive the following message: An unhandled exception of type 'System.UnauthorizedAccessException' occurred in System.dll . Additional information: Access

Serial Communication one to one

天大地大妈咪最大 提交于 2019-12-11 08:55:40
问题 If this is a stupid question, please don't mind me. But I spent some time trying to find the answer but I couldn't get anything solid. Maybe this is a hardware question, but I figured I'd try here first. Does Serial Communication only work one to one? The reason this came up is because I had an arduino board listening for communication on its serial port. I had a python script feed bytes to the port as well. However, whenever I opened up the arduino's serial monitor, the connection with the

Large data transmission in Bluetooth Low Energy between HM10 with Arduino & Android BLE

廉价感情. 提交于 2019-12-11 08:37:15
问题 Have an issue receiving data from HM-10 Bluetooth Low Energy in my android App I did half the way. what I did is : sending data from the phone to the BLE and i succeeded now i want to receive data to my phone from the BLE. (Arduino) --> (HM-10 BLE) ->-->-BLE CONNECTION-->-->- (ANDROID APP) So I'm sending dummy data from Arduino but I cannot receive it in the app. here's the class that responsible to send data from Android to the BLE Module public class DeviceControlActivity extends Activity {

ASCII 7x5 side-feeding characters for led modules

心不动则不痛 提交于 2019-12-11 08:11:57
问题 I am looking at the code for the font file here: http://www.openobject.org/opensourceurbanism/Bike_POV_Beta_4 The code starts like this: const byte font[][5] = { {0x00,0x00,0x00,0x00,0x00}, // 0x20 32 {0x00,0x00,0x6f,0x00,0x00}, // ! 0x21 33 {0x00,0x07,0x00,0x07,0x00}, // " 0x22 34 {0x14,0x7f,0x14,0x7f,0x14}, // # 0x23 35 {0x00,0x07,0x04,0x1e,0x00}, // $ 0x24 36 {0x23,0x13,0x08,0x64,0x62}, // % 0x25 37 {0x36,0x49,0x56,0x20,0x50}, // & 0x26 38 {0x00,0x00,0x07,0x00,0x00}, // ' 0x27 39 {0x00

Matlab serial interface with Arduino is very slow

蓝咒 提交于 2019-12-11 07:47:13
问题 I am trying to establish a serial link in Matlab with an Arduino board. Reading data from the board goes well. However, writing data to the board takes about a second for each block of information I send. The code I am running to write data: s = serial(comprt,'BaudRate',9600,'DataBits',8); fopen(s); fprintf(s, '%c', 'c'); fprintf(s, '%u %u %u %u \n', [A B C D]); pause(1); fprintf(s, '%c', 'a'); pause(1); A, B, C, D are 8-bit numbers anywhere from 0 - 255, 'c' and 'a' are characters commands

Three-dimensional array arrives in wrong order at serial port

非 Y 不嫁゛ 提交于 2019-12-11 07:37:58
问题 For an university assignment I'm writing a java application that will run some game logic for an interactive LED table. The table itself is being controlled by either 2 Arduino Duemilanove or 1 Arduino Mega 2560. To give the Arduino(s) information about which LEDs should be lit in which color I send the data over the serial port from a Raspberry Pi 3b+ to the Arduinos. As the table consists of 14 LED strips with 14 LEDs per LED strip and each LED has 3 color values (RGB) I store the data

C# - Overwrite / Update text in TextBlock

南笙酒味 提交于 2019-12-11 07:18:31
问题 I am currently building a WPF application that receives and displays data from an Arduino using a SerialPort connection. I have managed to get the live data to display as it is received, however when the text reaches the bottom of the TextBlock the text stops. I would like to replace the old values with the new data coming in. Is this possible? This is my code public partial class MainWindow : Window { SerialPort sp = new SerialPort(); public MainWindow() { InitializeComponent(); } private

Serial communication (for Arduino) using Visual Studio 2010 and C

守給你的承諾、 提交于 2019-12-11 07:13:20
问题 I'm facing a slight issue at the moment. I am currently doing some video (image) detection and tracking using Microsoft Visual Studio 2010 Professional and OpenCV, and the result (of the vision system) is to control additional hardware via the Arduino platform. My code for the vision system works 100% and code on Arduino also works 100%, but I'm having an issue communicating via C / C++ from the PC to the Arduino board. (Can not use Visual Basic, etc.) Specifications at the moment: Windows 7