Betreff: Modul ESP32-4848S040

If doesn't fit into any other category ....
Helmut_number_one
Posts: 93
Joined: Fri Dec 09, 2022 10:03 am
Has thanked: 36 times
Been thanked: 8 times

Re: Betreff: Modul ESP32-4848S040

Post by Helmut_number_one »

I found a way, now I have to clean up my code before posting it..
Here my Panel with UDP switch. Version without timer (go back to first Page), without text in page , coming soon .
Video:
https://youtube.com/shorts/R8J1yXFfpnk
Edit_18.2.24 this attachments include Swich and text with UDP Toogle (with UDP11=0 or 1 - UDP42=0 or 1) the switch and write into txt with (TXT11-TXT42) sample "TXT11= 13,0 Grad"

In UDP Client_Socket is this a cmd:
//USCK_SendText(39372, "UDP11=1");
//USCK_SendText(39372, "TXT01= 23,3 Grad");
UDP11=1 set UDP_page1_relais1 = 1 and so on
Relais1 in Page 4 = UDP41=1 or 0
TXT11= "23,6 Grad" set page 1 text 1 to 23,6 Grad
Text in Page 4 Text 1 is TXT41= "xyz"
PWM Display per UDP TXT00= "200" or so.
Panel_PWM_UDP_4_Page_root.zip
You do not have the required permissions to view the files attached to this post.
audi2010
Posts: 1
Joined: Mon Feb 19, 2024 10:37 am
Has thanked: 2 times

Re: Betreff: Modul ESP32-4848S040

Post by audi2010 »

An example of a "vintage clock" done with Annex
IMG_7056.jpg
Thank you for your information and work.
I would try to play with vintage clock on my ESP 4848S040 and couldn't find the Code.
Where can I get it?
User avatar
cicciocb
Site Admin
Posts: 1989
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 426 times
Been thanked: 1329 times
Contact:

Re: Betreff: Modul ESP32-4848S040

Post by cicciocb »

[Local Link Removed for Guests] wrote: [Local Link Removed for Guests]Thu Feb 15, 2024 11:33 am I found a way, now I have to clean up my code before posting it..
Here my Panel with UDP switch. Version without timer (go back to first Page), without text in page , coming soon .
Video:
https://youtube.com/shorts/R8J1yXFfpnk
Edit_18.2.24 this attachments include Swich and text with UDP Toogle (with UDP11=0 or 1 - UDP42=0 or 1) the switch and write into txt with (TXT11-TXT42) sample "TXT11= 13,0 Grad"

In UDP Client_Socket is this a cmd:
//USCK_SendText(39372, "UDP11=1");
//USCK_SendText(39372, "TXT01= 23,3 Grad");
UDP11=1 set UDP_page1_relais1 = 1 and so on
Relais1 in Page 4 = UDP41=1 or 0
TXT11= "23,6 Grad" set page 1 text 1 to 23,6 Grad
Text in Page 4 Text 1 is TXT41= "xyz"
PWM Display per UDP TXT00= "200" or so.
Panel_PWM_UDP_4_Page_root.zip
I'm back from holidays and I'm happy to see that you are progressing.
Good news!
User avatar
cicciocb
Site Admin
Posts: 1989
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 426 times
Been thanked: 1329 times
Contact:

Re: Betreff: Modul ESP32-4848S040

Post by cicciocb »

[Local Link Removed for Guests] wrote: [Local Link Removed for Guests]Fri Feb 23, 2024 12:02 pm
An example of a "vintage clock" done with Annex
IMG_7056.jpg
Thank you for your information and work.
I would try to play with vintage clock on my ESP 4848S040 and couldn't find the Code.
Where can I get it?
I think I didn't published :oops:
User avatar
cicciocb
Site Admin
Posts: 1989
Joined: Mon Feb 03, 2020 1:15 pm
Location: Toulouse
Has thanked: 426 times
Been thanked: 1329 times
Contact:

Re: Betreff: Modul ESP32-4848S040

Post by cicciocb »

This is the code for the vintage clock.
All is included in the attached zip file

Code: [Local Link Removed for Guests]

' backlight at 50% (128/256)
pwm.setup 38, 7, 128 ' backlight

vga.pinout 11, 12, 13, 14, 0,   8, 20, 3, 46, 9, 10,  4, 5, 6, 7, 15,  16, 17, 18, 21
vga.delete

vga.init 13, 3 'set at 480x480 with 3 pages
tft.loadfont "/fonts/FreeSansBold20pt7b.bin", 10
tft.loadfont "/fonts/FreeMonoBold24pt7b.bin", 11

vga.fill black
vga.text.font 10
vga.text.color gold, black

vga.text.draw "Annex32-S3 - Demo", 20, 80
vga.text.draw "Vintage Clock", 20, 120
vga.text.draw "Resolution: 640 x 480", 20, 160
vga.show
pause 2000

act = 1
vga.writePage act ' active
vga.image "/img/clock1.bmp"
vga.showPage act  ' display

vga.copy 1, 2 ' copy the image from the buffer 1 to the buffer 2
i = 0
gosub  update_clock
timer0 500, update_clock

back = 1
ontouch touched
wait

update_clock:
  buf = (i and 1)
  vga.copy 2, buf ' copy the image from the buffer 2 to the buffer buf
  vga.WritePage buf' active
  t = timeunix(time$)
  h = (t / 3600 ) mod 12
  m = (t / 60) mod 60
  s = t mod 60
  
  'wlog t,h,m,s
  
  vga.needle 240, 240, 150, h*30 +180 , darkgreen, 12
  vga.needle 240, 240, 180, m*6 +180 , blue, 10
  vga.needle 240, 240, 200, s*6 +180 , red, 6
  vga.circle 240, 240, 10, white, 1
  vga.showPage buf  ' display
  incr i
return

touched:
  wlog touch.z
  vga.writePage 2 ' active
  incr back
  if back > 6 then back = 1
  vga.image str$(back, "/img/clock%d.bmp", 1)
  vga.showPage act  ' display
return

You do not have the required permissions to view the files attached to this post.
Post Reply