caramoan tour package

caramoan tour package

Author Topic: problem in receiving msg via gsm module and pic16f628a with .bas code  (Read 3058 times)

Offline paranz

  • Moderator
  • Nuclear Reactor
  • *****
  • Posts: 4525
  • Pogi/Ganda Points: 177
  • Gender: Male
  • 1/4W resistor specialist
    • RapidSignal Electronics
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #20 on: August 31, 2010, 08:27:52 PM »
^ Clarification lang, which e-gizmo GSM module are you using? the old BENQ GSM module (not being sold anymore since last year) or the newer SIM340DZ-based GSM/GPRS module?

Also, FYI, the SIM340DZ-based GSM/GPRS module is now being replaced by a SIM9000 module as of last week. SIM340 and SIM900 are pin compatible anyways.
PIC16 Programming Tutorial using MPLAB and Hi-Tech C
www.rapidsignalph.com/tutorials/pic16-tutorials

Arduino & gizDuino Tutorials
www.rapidsignalph.com/tutorials/arduino-tutorials

Philippine Electronics Forum

Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #20 on: August 31, 2010, 08:27:52 PM »

Offline jungardc2

  • Size AAA Battery
  • ***
  • Posts: 70
  • Pogi/Ganda Points: 0
  • Gender: Male
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #21 on: August 31, 2010, 09:09:42 PM »
^ Clarification lang, which e-gizmo GSM module are you using? the old BENQ GSM module (not being sold anymore since last year) or the newer SIM340DZ-based GSM/GPRS module?

Also, FYI, the SIM340DZ-based GSM/GPRS module is now being replaced by a SIM9000 module as of last week. SIM340 and SIM900 are pin compatible anyways.

SIM340DZ-based GSM/GPRS module po..wala na kasi yun BENQ..
carpe diem..

Philippine Electronics Forum

Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #21 on: August 31, 2010, 09:09:42 PM »

Offline paranz

  • Moderator
  • Nuclear Reactor
  • *****
  • Posts: 4525
  • Pogi/Ganda Points: 177
  • Gender: Male
  • 1/4W resistor specialist
    • RapidSignal Electronics
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #22 on: August 31, 2010, 09:47:30 PM »
I see.. we are using the same GSM module :)

I have interfacing problem with this GSM module before when using PIC16F877A with VDD = +5v.

In my experiment, I used 3 different voltage translation circuits for testing.
1. Direct connect GSM_TX to MCU_RX and voltage divider circuit for MCU_TX to GSM_RX
2. Using NPN transistor fro GSM_TX to MCU_RX and signal diode for MCU_TX to GSM_RX
3. Using buffer chip

All configurations i tested with the PC + Hyperterminal and all work fine.

Now, when i tested to a PIC16F877A, (1) doesn't work reliably. I run the PIC + GSM module setup with a debugger (eICD2), and i can see 1 or 2 received characters that are wrong, i.e. instead of +CMTI="SM",1 in the buffer i get +CMTh = "SM"&1.

I tried (3) and it worked perfectly. I used a HC125 buffer chip and it worked. Pero hirap hanapin ang ganito na IC.

So I tried (2) also and it doesn't worked sometimes, with wrong characters received but not as often or as unreliable as (1). In my setup right now (2) worked just fine, but testing it on several GSM modules (10 GSM modules to be precise, during a seminar workshop last week in e-gizmo  ;D)  it still not as reliable.

PIC16 Programming Tutorial using MPLAB and Hi-Tech C
www.rapidsignalph.com/tutorials/pic16-tutorials

Arduino & gizDuino Tutorials
www.rapidsignalph.com/tutorials/arduino-tutorials

Philippine Electronics Forum

Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #22 on: August 31, 2010, 09:47:30 PM »

Offline jungardc2

  • Size AAA Battery
  • ***
  • Posts: 70
  • Pogi/Ganda Points: 0
  • Gender: Male
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #23 on: August 31, 2010, 10:25:26 PM »
I see.. we are using the same GSM module :)

I have interfacing problem with this GSM module before when using PIC16F877A with VDD = +5v.

In my experiment, I used 3 different voltage translation circuits for testing.
1. Direct connect GSM_TX to MCU_RX and voltage divider circuit for MCU_TX to GSM_RX
2. Using NPN transistor fro GSM_TX to MCU_RX and signal diode for MCU_TX to GSM_RX
3. Using buffer chip

All configurations i tested with the PC + Hyperterminal and all work fine.

Now, when i tested to a PIC16F877A, (1) doesn't work reliably. I run the PIC + GSM module setup with a debugger (eICD2), and i can see 1 or 2 received characters that are wrong, i.e. instead of +CMTI="SM",1 in the buffer i get +CMTh = "SM"&1.

I tried (3) and it worked perfectly. I used a HC125 buffer chip and it worked. Pero hirap hanapin ang ganito na IC.

So I tried (2) also and it doesn't worked sometimes, with wrong characters received but not as often or as unreliable as (1). In my setup right now (2) worked just fine, but testing it on several GSM modules (10 GSM modules to be precise, during a seminar workshop last week in e-gizmo  ;D)  it still not as reliable.


ahhhhhhh...salamat po sa experiment ninyo po..so this explains it..sa (2) switching npn lang po ba gawin ko? may 3.3v na zener kaya available? hehe try ko maghanap po pati yun hc125 (3)..
carpe diem..

Philippine Electronics Forum

Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #23 on: August 31, 2010, 10:25:26 PM »

Offline 0b00000111

  • Technical People
  • Solar Power Satellite
  • *****
  • Posts: 6129
  • Pogi/Ganda Points: 398
  • There is no delight in owning anything unshared.
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #24 on: August 31, 2010, 10:25:58 PM »
Quote
im trying this experiment po pero bakit po sa post na ito direct connected na si  GSM_TX sa MCU_RX:
http://www.electronicslab.ph/forum/index.php/topic,13813.0.html

and we all know that logic high level is  2.0v above and logic low level is from 0 to 0.8v..

ano ang voltage level ng GSM TX at idle?  sa PIC16F628A, based from block diagram ng RB1/RX pin, dumadaan ito sa schmitt trigger sa UART receive mode...
 
then based sa Input High Voltage parameter D040, pag schmitt trigger =  ang minimum na input high voltage is 0.8*Vdd. assuming 5V  ang gamit mo, 4V ang minimum input high voltage
E-Gizmo Mechatronix Central: www.e-gizmo.com

Tel #: (63)(2) 536-3378
Globe +63915-973-7691
Smart +63921-779-0748

Location Map

YM: julie.egizmo  aka Born2BeWired  ;D

Philippine Electronics Forum

Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #24 on: August 31, 2010, 10:25:58 PM »

Offline paranz

  • Moderator
  • Nuclear Reactor
  • *****
  • Posts: 4525
  • Pogi/Ganda Points: 177
  • Gender: Male
  • 1/4W resistor specialist
    • RapidSignal Electronics
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #25 on: August 31, 2010, 10:48:53 PM »

then based sa Input High Voltage parameter D040, pag schmitt trigger =  ang minimum na input high voltage is 0.8*Vdd. assuming 5V  ang gamit mo, 4V ang minimum input high voltage

Ayun, dapat minimum of 4V ang Logic 1 papasok ng MCU_RX..

GSM_TX Vpk-pk is around 2.8V only, (Logic 0 = 0.1V, Logic = +2.9V) as shown in my scope.

For reliable UART reception by the PIC_RX pin, GSM_TX pin should transmit a logic 1 that is more than +4.0V. Kailangan talaga ng voltage level translator circuit to convert +2.9V to +5V.
PIC16 Programming Tutorial using MPLAB and Hi-Tech C
www.rapidsignalph.com/tutorials/pic16-tutorials

Arduino & gizDuino Tutorials
www.rapidsignalph.com/tutorials/arduino-tutorials

Offline paranz

  • Moderator
  • Nuclear Reactor
  • *****
  • Posts: 4525
  • Pogi/Ganda Points: 177
  • Gender: Male
  • 1/4W resistor specialist
    • RapidSignal Electronics
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #26 on: August 31, 2010, 10:55:05 PM »
ahhhhhhh...salamat po sa experiment ninyo po..so this explains it..sa (2) switching npn lang po ba gawin ko? may 3.3v na zener kaya available? hehe try ko maghanap po pati yun hc125 (3)..

Go for (3). I think meron LVC125 sa gizmo. For +3.3V you can always use a LM317 voltage regulator. But i typically use RT9163 voltage regulator from e-gizmo so that i can input +5v to it from the existing 7805 regulator on the PIC circuit and get an +3.3V output. With LM317 i need to use another DC regulator which is unwieldy for my setup, so RT9163 (or other LDO regulators) is better. Yun nga lang SOIC ito and not through-hole.
PIC16 Programming Tutorial using MPLAB and Hi-Tech C
www.rapidsignalph.com/tutorials/pic16-tutorials

Arduino & gizDuino Tutorials
www.rapidsignalph.com/tutorials/arduino-tutorials

Offline paranz

  • Moderator
  • Nuclear Reactor
  • *****
  • Posts: 4525
  • Pogi/Ganda Points: 177
  • Gender: Male
  • 1/4W resistor specialist
    • RapidSignal Electronics
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #27 on: August 31, 2010, 10:57:54 PM »
^ or use VDD = +3.3V instead of +5V. Problem solve :D
PIC16 Programming Tutorial using MPLAB and Hi-Tech C
www.rapidsignalph.com/tutorials/pic16-tutorials

Arduino & gizDuino Tutorials
www.rapidsignalph.com/tutorials/arduino-tutorials

Offline 0b00000111

  • Technical People
  • Solar Power Satellite
  • *****
  • Posts: 6129
  • Pogi/Ganda Points: 398
  • There is no delight in owning anything unshared.
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #28 on: August 31, 2010, 11:13:35 PM »
or pwede din ibaba na lang nya yung Vdd ng pic16f628a (but im not sure kung ano crystal value ni TS) para maabot yung 0.8*Vdd + some allowance...


or eto, ngayon ko lang naisip (cheap voltage level translator for this gsm modem).... resistor values are around 4.7k to 10k siguro hehehe



pag idle 2.8V sa GSM TX, OFF yung transistor, Vbe=0V, 5V ang papunta sa PIC
pag nag 0V ang GSM modem TX, may 0.7V sa Vbe, ON ang transistor, mag 0V papunta sa PIC....
(sorry kung puro ideal values hehehe)

unsimulated pa... pa comment na lang kung may mali or meron akong di naiconsider (tulad ng source/sink current nung TX ng gsm modem)... hehehe
E-Gizmo Mechatronix Central: www.e-gizmo.com

Tel #: (63)(2) 536-3378
Globe +63915-973-7691
Smart +63921-779-0748

Location Map

YM: julie.egizmo  aka Born2BeWired  ;D

Offline paranz

  • Moderator
  • Nuclear Reactor
  • *****
  • Posts: 4525
  • Pogi/Ganda Points: 177
  • Gender: Male
  • 1/4W resistor specialist
    • RapidSignal Electronics
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #29 on: August 31, 2010, 11:44:51 PM »
^ yup that (2) circuit i'm recommending to TS. Medyo hirap lang kumuha ng stable na +2.8V
PIC16 Programming Tutorial using MPLAB and Hi-Tech C
www.rapidsignalph.com/tutorials/pic16-tutorials

Arduino & gizDuino Tutorials
www.rapidsignalph.com/tutorials/arduino-tutorials

Offline 0b00000111

  • Technical People
  • Solar Power Satellite
  • *****
  • Posts: 6129
  • Pogi/Ganda Points: 398
  • There is no delight in owning anything unshared.
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #30 on: September 01, 2010, 08:26:12 AM »
^^ pwede din revise na lang yung sa may base section for voltage divider for the ~2.8V (coming from the 5V regulator)...
E-Gizmo Mechatronix Central: www.e-gizmo.com

Tel #: (63)(2) 536-3378
Globe +63915-973-7691
Smart +63921-779-0748

Location Map

YM: julie.egizmo  aka Born2BeWired  ;D

Offline jungardc2

  • Size AAA Battery
  • ***
  • Posts: 70
  • Pogi/Ganda Points: 0
  • Gender: Male
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #31 on: September 04, 2010, 11:25:29 AM »
^ yup that (2) circuit i'm recommending to TS. Medyo hirap lang kumuha ng stable na +2.8V
im trying hard to try this cricuit po..hirap nga mag2.8 v
anyway meron pala akong 74LS125..
meron na naman ako narereceive galing sa GSM but at 9600 baud rate i am always receiving only a limit of two characters and most of the time it is "at"..bakit ganun po?
i tried decreasing the baud rate and the character are different but bakit po 2 characters lang pa rin po narereceicve ko?
carpe diem..

Offline 0b00000111

  • Technical People
  • Solar Power Satellite
  • *****
  • Posts: 6129
  • Pogi/Ganda Points: 398
  • There is no delight in owning anything unshared.
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #32 on: September 04, 2010, 12:09:07 PM »
^^ kahit sa hyperterminal ganun rin?
E-Gizmo Mechatronix Central: www.e-gizmo.com

Tel #: (63)(2) 536-3378
Globe +63915-973-7691
Smart +63921-779-0748

Location Map

YM: julie.egizmo  aka Born2BeWired  ;D

Offline jungardc2

  • Size AAA Battery
  • ***
  • Posts: 70
  • Pogi/Ganda Points: 0
  • Gender: Male
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #33 on: September 04, 2010, 12:10:48 PM »
^^ kahit sa hyperterminal ganun rin?

hindi po..
carpe diem..

Offline Didoyskie

  • CR2032 Battery
  • **
  • Posts: 7
  • Pogi/Ganda Points: 0
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #34 on: September 06, 2010, 10:58:12 AM »
ok lang ba to? direct connection from mcu to gsm...

pic16f628a(BOREN_OFF) yung supply galing sa VBat ng sim340DZ module.

nung tinest ko po... success sya...  ;)


Offline jungardc2

  • Size AAA Battery
  • ***
  • Posts: 70
  • Pogi/Ganda Points: 0
  • Gender: Male
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #35 on: September 06, 2010, 11:19:12 AM »
ok lang ba to? direct connection from mcu to gsm...

pic16f628a(BOREN_OFF) yung supply galing sa VBat ng sim340DZ module.

nung tinest ko po... success sya...  ;)
you mean po isang psu lang gamit nyo?


carpe diem..

Offline Didoyskie

  • CR2032 Battery
  • **
  • Posts: 7
  • Pogi/Ganda Points: 0
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #36 on: September 06, 2010, 11:33:04 AM »
oo ung galing dun sa pin vbat ng sim340DZ...

around 3+V ata un eh...

gumagana nga sya ngayon eh... nakakareceive sya ng kahit anong word na iparead ko ("RING","OK")

tapos tama naman ung respond ng MCU.

Offline jungardc2

  • Size AAA Battery
  • ***
  • Posts: 70
  • Pogi/Ganda Points: 0
  • Gender: Male
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #37 on: September 06, 2010, 11:41:03 AM »
yun bagong gsm ng e-gizmo po ba gamit ninyo?
carpe diem..

Offline Didoyskie

  • CR2032 Battery
  • **
  • Posts: 7
  • Pogi/Ganda Points: 0
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #38 on: September 06, 2010, 11:42:43 AM »
oo sim340DZ kakabili ko nga lang nito nung july... eto n b ung bago?

Offline jungardc2

  • Size AAA Battery
  • ***
  • Posts: 70
  • Pogi/Ganda Points: 0
  • Gender: Male
Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #39 on: September 06, 2010, 11:50:29 AM »
pareho po pala tayo..sige po salamat sa info..nakita ko na yun vbat. separate kasi yun psu q taps 2 characters lng limit ng nakukuha ko galing sa gsm papunta mcu..
carpe diem..

Philippine Electronics Forum

Re: problem in receiving msg via gsm module and pic16f628a with .bas code
« Reply #39 on: September 06, 2010, 11:50:29 AM »

 

Privacy Policy

Contact Us: elabph@yahoo.com