arduino

My GPS can't share the location by SMS

青春壹個敷衍的年華 提交于 2019-12-31 05:16:05
问题 I have some problem with my project. I am using SIM800L and GPS Neo6MV2 with arduino genuine uno. My project is sending GPS location by message. But, the message i received only contained long = 0,000000 lat = 0, 000000. Here is my code: #include <TinyGPS++.h> TinyGPSPlus gps; //float latitude, longitude; int myled=13; #include <SoftwareSerial.h> SoftwareSerial SIM800L(7, 8); //SoftwareSerial gps_serial(2,3); String response; int lastStringLength = response.length(); String latitude,

Intel Edison MRAA module not working

本小妞迷上赌 提交于 2019-12-30 18:23:07
问题 I recently downloaded the Intel XDK IOT version and used the LED pin 13 Blink sample. I then uploaded the program onto the Edison, but it came up with a few errors; One of them being that it could not find the MRAA module. The sample code that came with it was: main.js: var mraa = new require("mraa"); //require mraa console.log('MRAA Version: ' + mraa.getVersion()); //write the mraa version to the Intel XDK console var myOnboardLed = new mraa.Gpio(13); //LED hooked up to digital pin 13 (or

Android cannot talk to Arduino using AVRDUDE

北慕城南 提交于 2019-12-30 07:14:12
问题 I am using AVRDUDE for Android (http://code.google.com/p/andavr/). I can compile the C code. I can run $ avr-gcc -Os -DF_CPU=16000000UL -mmcu=atmega328p -c -o led.o led.c $ avr-gcc -mmcu=atmega328p led.o -o led $ avr-objcopy -O ihex -R .eeprom led led.hex all without issues. Then I try to run: avrdude -F -V -c arduino -p ATMEGA328P -P /dev/bus/usb/002/002 -b 115200 -C /data/data/jackpal.androidterm/local/etc/avrdude.conf -U flash:w:led.hex The result is: avrdude: ser_open(): can't open device

avrdude: ser_open(): can't open device “/dev/ttyACM0”: Device or resource busy

无人久伴 提交于 2019-12-30 01:02:35
问题 I am Linux Mint user.I am dealing with Arduino Yun.I am compiling Arduino program.After that I am uploading to Arduino Yun.Then I get these error.Can you help me? 回答1: you first need to make sure you have the correct read/write rights, as described here, esentially enter following commands: $ sudo adduser <username> dialout $ sudo chmod a+rw /dev/ttyACM0 the '/dev/ttyACM0' is the port your arduino is connected to, it should be listed in the /dev folder of your root. second: after you have

总线SPI的Arduino库函数

安稳与你 提交于 2019-12-29 11:28:58
SPI 基本知识   SPI:高速同步串行口。是一种标准的四线同步双向串行总线。   SPI,是英语Serial Peripheral interface的缩写,顾名思义就是 串行外围设备接口 。是Motorola首先在其MC68HCXX系列处理器上定义的。SPI接口主要应用在 EEPROM,FLASH, 实时时钟 ,AD转换器,还有 数字信号处理器 和数字信号解码器之间。SPI,是一种高速的,全双工,同步的通信总线,并且在芯片的管脚上只占用四根线,节约了芯片的管脚,同时为PCB的布局上节省空间,提供方便,正是出于这种简单易用的特性,如今越来越多的芯片集成了这种 通信协议 ,比如AT91RM9200。   SPI总线系统是一种同步 串行外设接口 ,它可以使MCU与各种外围设备以串行方式进行通信以交换信息。外围设置FLASHRAM、网络控制器、LCD显示驱动器、A/D转换器和MCU等。SPI总线系统可直接与各个厂家生产的多种标准外围器件直接接口,该接口一般使用4条线:串行时钟线(SCLK)、主机输入/从机输出数据线MISO、主机输出/从机输入数据线MOSI和低电平有效的从机选择线SS(有的SPI接口芯片带有中断信号线INT、有的SPI接口芯片没有主机输出/从机输入数据线MOSI)。   SPI的通信原理很简单,它以主从方式工作,这种模式通常有一个主设备和一个或多个从设备

Different int sizes on my computer and Arduino

你。 提交于 2019-12-29 09:04:46
问题 Im working on a sparetime project, making some server code to an Arduino Duemilanove, but before I test this code on the controller I am testing it on my own machine (An OS X based macbook). I am using ints some places, and I am worried that this will bring up strange errors when code is compiled and run on the Arduino Duemilanove because the Arduino handles ints as 2 bytes, and my macbook handles ints as 4 bytes. Im not a hardcore C and C++ programmer, so I am in a bit of worry how an

Different int sizes on my computer and Arduino

只愿长相守 提交于 2019-12-29 09:03:23
问题 Im working on a sparetime project, making some server code to an Arduino Duemilanove, but before I test this code on the controller I am testing it on my own machine (An OS X based macbook). I am using ints some places, and I am worried that this will bring up strange errors when code is compiled and run on the Arduino Duemilanove because the Arduino handles ints as 2 bytes, and my macbook handles ints as 4 bytes. Im not a hardcore C and C++ programmer, so I am in a bit of worry how an

Embedding Matplotlib live plot data from Arduino in tkinter canvas

a 夏天 提交于 2019-12-29 08:02:42
问题 I've only been using Python for a couple of weeks. I have no problems plotting the data coming in from the Arduino with Matplotlib. However the plot shows up as a pop-window and I would like that plot to only show up in a canvas in the root window of the GUI I'm making with tkinter. I've tried multiple combinations of things and I can't get it to work. If I just add the plot values to the code, let's say: a.plot([1, 2, 3, 4, 5], [2, 3, 4, 5, 6, 7]) it works fine, so my main problem then is

Embedding Matplotlib live plot data from Arduino in tkinter canvas

╄→гoц情女王★ 提交于 2019-12-29 08:01:59
问题 I've only been using Python for a couple of weeks. I have no problems plotting the data coming in from the Arduino with Matplotlib. However the plot shows up as a pop-window and I would like that plot to only show up in a canvas in the root window of the GUI I'm making with tkinter. I've tried multiple combinations of things and I can't get it to work. If I just add the plot values to the code, let's say: a.plot([1, 2, 3, 4, 5], [2, 3, 4, 5, 6, 7]) it works fine, so my main problem then is

Python to automatically select serial ports (for Arduino)

房东的猫 提交于 2019-12-28 02:35:28
问题 Currently the python program must know which port a device (Arduino) is on before Python can communicate the device. Problem: Whenever the device is plugged out and back in, its COM port changes, so the correct serial port must be given to Python again for it to find the device. How can Python (using pySerial ) automatically search for the correct serial port to use? Is it possible for python to correctly identify the device on a serial port as an Arduino? 回答1: Use the following code to see