Modem responds with junk value for AT Command using serial programming - serial-port

Background
I am trying to connect to a serial GSM - modem of Wavecom type.
I was able to communicate with the modem using the guide
http://www.easysw.com/~mike/serial/serial.html
on my Ubuntu machine.
but when I tried to connect it through a device with serial port and running on Linux kernel Linux 2.6.14.7-tiny1-WR1.3al_small I get junk data returned. I have tried all of the baud values to connect to the modem. It connected on 115200 baud value when it was working, but the same value does not work from this Kernel. Its a ARM target machine. note : I cross compiled the code for ARM
Question
Do I need a driver for a modem to just be connected through a serial terminal Program ?

Please make sure that the RS232/TTL converter of your ARM board is working correctly. for example you can connect it to your Ubuntu machine at first and transmit something with a terminal program.
question : 1 ) Do i need a driver for Modem to just be connected through a Serial Terminal Program ?
No.You can connect to your GSM modem simply by having a serial port and a terminal program.

Related

SIM900 module not responding on hardware COM port

I've got my sim900 module working with arduino by using their software serial library, however, I want to eliminate arduino from the equation and have serial communication directly to sim900 module.
I'm using putty as my terminal emulator. It's serial is configured to COM1 19200 8 N 1 the same as device manager configuration for this port.
I connect straight from hardware serial on my PCs motherboard into serial-to-ttl interface board which connects to sim900 module. The board has 4 pins - VCC GND TX RX. They're all connected to my sim900 hardware serial as follows: VCC=5V GND=GND TX=TX RX=RX (Yes I know that it's always actually TX=RX and RX=TX, but when I connect it that way my interface board doesn't blink any led to indicate a transfer whereas it does when I connect TX=TX and RX=RX). The switch on the module is set to hardware serial pins as well.
So the only thing that happens when I send AT commands such as AT or ATI and press enter is that puttys cursor comes back to the beginning of command that I typed. No response.
I'm thinking that I'm not doing something that the arduinos software serial port is doing when it sends commands to sim900.
Can anyone help please ? It's literally been days of trying different configurations with no results.
In that time besides getting sim900 working with arduino software serial I verified that the hardware serial port on my motherboard is working correctly and the interface board is working correctly as well.

Use debug serial pins to connect with a serial device on beaglebone rev c

I Have a RF module that communicate using serial port using RS232. It works in a normal computer.
I noticed that beaglebone has a serial debug slot and I tried to connect my device to it but, I can't send or receive messages using the serial debug slot.
If I connect the beaglebone to usb converting to RS232, I'll be able to communicate with my RF module. And I tested to connect by SSH using the serial slot and worked.
But I would like to use USB for another purpose. Is there a serial pins to be compatible with RS232?

Implementing I2C slave with FT201XB via USB

I've been trying to test a FT201XQ USB-I2C breakout board: UMFT201XB-01, so I can connect it to a master device such as an Arduino and sniff what that device is sending through I2C.
To see the output of the slave device I have successfully configured a Virtual COM PORT by installing the D2XX drivers provided by ftdchip.com. I can open the serial port through puTTY and everything seems fine in that regard.
Then, i've loaded the "master_writer" example on my Arduino, which sends 1 byte at a time to an address (0x22 is specified in the UM201XB-01 datasheet as the default address).
Nothing seems to happen in the COM port that i've earlier opened. Do I need to configure/program the FTDI device in some way? In that case, how can I do it, in a general way?
UMFT201XB-01 board http://www.ftdichip.com/Support/Documents/DataSheets/Modules/DS_UMFT201_220_230XB.pdf
Thank you in advance, and sorry if this is a "noob" question : P

avrdude: error: buffered memory access not supported

I am trying to upload this firmware sck_beta_v0_8_6 via Arduino 1.0.5-r2.
I have chosen LilyPad Arduino USB as the board. The device is a Smart Citizen Kit Urban Shield v.1.1.
The upload fails with the following error message:
Found programmer: Id = "BÛR"; type =
Software Version = . ; Hardware Version = .
avrdude: error: buffered memory access not supported. Maybe it isn't
a butterfly/AVR109 but a AVR910 device?
What am I doing wrong?
Sometimes, a different USB cable will make all the difference. There is a wide range in the quality of cables on the market, and sometimes, you get one on the ragged edge of acceptable.
The Arduino lilypad seems to be particularly susceptible to this. Glad this helped.
Press the Reset Button before upload the code, until you hear the "unplug" sound (in windows). Open the IDE and try it again
I had the same error message trying to upload a sketch to an Arduino Leonardo board from a Levovo laptop using Arduino ver 1.0.6. Both Device Manager and Arduino showed the board connected on COM3. Arduino also gave an error message that COM3 was being used by another App. I tried changing USB cables but got the same message. What worked was changing the USB outlet from the top right rear on the Lenovo to the bottom right rear outlet. It connected on COM8 and I was able to upload the sketch. Understand there are speed differences between the two outlets. Now all I need to do is figure out why I cannot upload sketches to the same Leonardo board on my HP laptop with Windows 10 and the most recent Arduino version. Connects on COM6 but hangs up when uploading. (Note: Also had to edit some Arduino library files that worked on ver 1.0.6 but showed compile errors in the latest version.)
I had the same error, but I later found that I had the wrong Arduino type selected, instead of Nano I had Yun.
I had the same issue when trying to upload code into Arduino Micro ( Chinese clone ). Spending hours on Google, flashing new bootloader - still nothing. Physical reset and opening COM port with boundrate 1200 doesn't work. Why?
I HAVE ATMEGA168 INSTEAD OF ATMEGA32u4!
Google is telling, that Arduino Micro got Atmega32u4, but my clone got Atmega168! First of all, check what atmega type do you have by lookup on black soldered chip on Arduino.
So instead of choose "Arduino Micro" on "Board" menu, i choose Arduino Nano and everything works!
I get this same error, avrdude: error: buffered memory access not supported also with garbage-looking output with programmer id # with versions ., when I point avrdude at the serial port of the stock main firmware of my Leonardo-compatible breakout board instead of the serial port offered during the bootloader; it seems that the latter is what avrdude can program?
The normal initial output when actually connecting to the bootloader would be something like:
Connecting to programmer: .
Found programmer: Id = "CATERIN"; type = S
Software Version = 1.0; No Hardware Version given.
To get to the bootloader you can either
press the reset button (if you don't have a reset button, connecting reset to ground), or
briefly connect to the main firmware's serial port at 1200 bps and disconnect
The bootloader will present a different serial USB device than the main firmware's serial USB device, so it may get assigned a different serial port number in your OS, usually the next available one. For instance in Windows my Leonardo-compatible main firmware was assigned COM3 and the bootloader was assigned COM4.
A python script, courtesy of https://nicholaskell.wordpress.com/tag/leonardo/, for doing this serial 'knock':
reset.py:
#!/usr/bin/env python
import serial, sys
serialPort = sys.argv[1]
ser = serial.Serial(
port=serialPort,
baudrate=1200,
parity=serial.PARITY_NONE,
stopbits=serial.STOPBITS_ONE,
bytesize=serial.EIGHTBITS
)
ser.isOpen()
ser.close() # always close port
In Windows land, I have a cmd script for using this in a virtualenv
reset.cmd:
"C:\Program Files (x86)\Python37-32\Scripts\virtualenv.exe" pyreset_virtualenv
pyreset_virtualenv\Scripts\pip.exe install pyserial
pyreset_virtualenv\Scripts\python reset.py COM3
pause
adjust to suit your serial port and python path.
Either way, after getting the bootloader connected, you have a brief window of a couple of seconds where avrdude can connect to the new serial port to start programming before the bootloader will go into the main firmware again, at which point you'll have to do the reset again. So, once you figure out the bootloader serial port, you'll want to prepare the avrdude command line to run in advance, so you can launch it without delay after the reset.
While this answer isn't specific to the lilypad, you need to reset the board to write or read from/to the memory. However, If you are using avrdude in the terminal you must send a specific baudrate(1200 for the Leonardo) then close, wait 2 seconds, and open the port. At that point you can read and write to and from your Arduino. I achieved this using python.
Along the lines of:
Import serial
Import time
Import os
Seri=serial.Serial(yourConnectedPort, specificBaudRate)
Seria.close()
time.sleep(2)
Seri.open()
os.system(your avrdude command)

USB to Serial emulation

I bought this magnetic strip reader writer (MSRE106) and I use USB adapter to connect it to my laptop because I have no serial port in my computer. But now I have a problem since the software of the device recognizes only serial ports on windows. After looking up I found someone that wrote a python script for Linux (found here The Script).
Still even in this python script in the settings file it has this variable
## Com port.
COM = "COM1"
How can I change this to be one of my USB ports instead of a serial one because I have none
This script is made to use serial port as well, which means you can't just modify COM="USB1" or whatever to use your USB adapter. If you have a look at line 264 a serial port is open using function SerialPort().
To fix this issue you must install your USB adapter's driver that will emulate a serial port and create a fake COM1 you can use with this script or the original software of the MSRE106.

Resources