{"id":626,"date":"2021-09-20T13:01:10","date_gmt":"2021-09-20T11:01:10","guid":{"rendered":"https:\/\/automatico.freevar.com\/?page_id=626"},"modified":"2021-09-27T08:44:52","modified_gmt":"2021-09-27T06:44:52","slug":"bbcbasic-applicazioni","status":"publish","type":"page","link":"https:\/\/automatico.freevar.com\/index.php\/cp-m-80-2\/bbc-basic\/bbcbasic-applicazioni\/","title":{"rendered":"BBCBasic &#8211; ESP32VGA"},"content":{"rendered":"<p><span style=\"font-size: 14pt;\">Here the list of a test program for the modified BBCBasic, for the sound you need to connect a headphone or a pair of loudspeakers to the audio output of the ESP32 terminal:<\/span><\/p>\n<pre class=\"brush: vb; title: ; notranslate\" title=\"\">\r\n10 REM SET GRAPHIC MODE\r\n20 MODE 1\r\n30 REM\r\n40 REM ** POINTS **\r\n50 FOR I = 0 TO 100\r\n60 REM Set random pen color\r\n70 R=RND(1)*255:G=RND(1)*255:B=RND(1)*255\r\n80 GCOL R,G,B\r\n90 REM Draw a pixel at random position\r\n100 X=RND(1)*640\r\n110 Y=RND(1)*480\r\n120 PLOT X,Y\r\n130 NEXT I\r\n140 DUR = 200\r\n150 FOR FREQ = 100 TO 2000 STEP 50\r\n160 GOSUB 430\r\n170 NEXT FREQ\r\n180 FOR I=1 TO 120\r\n190 MOVE 0,4\r\n200 NEXT I\r\n210 CLG\r\n220 REM\r\n230 REM ** LINES **\r\n240 FOR I = 0 TO 100\r\n250 REM Set random pen color\r\n260 R=RND(1)*255:G=RND(1)*255:B=RND(1)*255\r\n270 GCOL R,G,B\r\n280 REM Draw a line\r\n290 X1=RND(1)*640: Y1=RND(1)*480\r\n300 X2=RND(1)*640: Y2=RND(1)*480\r\n310 DRAW X1,Y1,X2,Y2\r\n320 NEXT I\r\n330 DUR = 200\r\n340 FOR FREQ = 2000 TO 100 STEP -50\r\n350 GOSUB 430\r\n360 NEXT FREQ\r\n370 FOR I=1 TO 120\r\n380 MOVE 4,0\r\n390 NEXT I\r\n400 CLG\r\n410 MODE 0\r\n420 END\r\n430 REM Generate a sound sine waveform (0),\r\n440 REM frequency Hertz, duration in milliseconds, audio volume max\r\n450 SOUND 0,FREQ,DUR,127\r\n460 FOR I=1 TO 100:NEXT I\r\n470 RETURN\r\n<\/pre>\n<div class=\"pvc_clear\"><\/div>\n<p id=\"pvc_stats_626\" class=\"pvc_stats all  \" data-element-id=\"626\" style=\"\"><i class=\"pvc-stats-icon medium\" aria-hidden=\"true\"><svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"far\" data-icon=\"chart-bar\" role=\"img\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 512 512\" class=\"svg-inline--fa fa-chart-bar fa-w-16 fa-2x\"><path fill=\"currentColor\" d=\"M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z\" class=\"\"><\/path><\/svg><\/i> <img loading=\"lazy\" decoding=\"async\" width=\"16\" height=\"16\" alt=\"Loading\" src=\"https:\/\/automatico.freevar.com\/wp-content\/plugins\/page-views-count\/ajax-loader-2x.gif\" border=0 \/><\/p>\n<div class=\"pvc_clear\"><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Here the list of a test program for the modified BBCBasic, for the sound you need to connect a headphone or a pair of loudspeakers to the audio output of the ESP32 terminal: 10 REM SET GRAPHIC MODE 20 MODE 1 30 REM 40 REM ** POINTS ** 50 FOR I = 0 TO 100 [&hellip;]<\/p>\n<div class=\"pvc_clear\"><\/div>\n<p id=\"pvc_stats_626\" class=\"pvc_stats all  \" data-element-id=\"626\" style=\"\"><i class=\"pvc-stats-icon medium\" aria-hidden=\"true\"><svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"far\" data-icon=\"chart-bar\" role=\"img\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 512 512\" class=\"svg-inline--fa fa-chart-bar fa-w-16 fa-2x\"><path fill=\"currentColor\" d=\"M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z\" class=\"\"><\/path><\/svg><\/i> <img loading=\"lazy\" decoding=\"async\" width=\"16\" height=\"16\" alt=\"Loading\" src=\"https:\/\/automatico.freevar.com\/wp-content\/plugins\/page-views-count\/ajax-loader-2x.gif\" border=0 \/><\/p>\n<div class=\"pvc_clear\"><\/div>\n","protected":false},"author":1,"featured_media":0,"parent":605,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-626","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/pages\/626"}],"collection":[{"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/comments?post=626"}],"version-history":[{"count":7,"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/pages\/626\/revisions"}],"predecessor-version":[{"id":739,"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/pages\/626\/revisions\/739"}],"up":[{"embeddable":true,"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/pages\/605"}],"wp:attachment":[{"href":"https:\/\/automatico.freevar.com\/index.php\/wp-json\/wp\/v2\/media?parent=626"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}