Hirdetés
- Geri Bátyó: Agglegénykonyha 10 – Alapanyagok/készételek többféle felhasználása
- Sub-ZeRo: Euro Truck Simulator 2 & American Truck Simulator 1 (esetleg 2 majd, ha lesz) :)
- MasterDeeJay: Harc a DDR5 árak ellen
- djculture: Éhezők ssd és memória viadala.
- GoodSpeed: Munkaügyi helyzet Hajdú-Biharban: észak és dél
- Real Racing 3 - Freemium csoda
- D1Rect: Nagy "hülyétkapokazapróktól" topik
- Luck Dragon: Asszociációs játék. :)
- sziku69: Fűzzük össze a szavakat :)
- sziku69: Szólánc.
-
LOGOUT
Arduino hardverrel és szoftverrel foglakozó téma. Minden mikrovezérlő ami arduinoval programozható, és minden arduino program, board, és hardverrel kapcsolatos kérdések helye.
Új hozzászólás Aktív témák
-
peter1998
tag
Egy enc28j60-as ethernet modult sikerült beszereznem.Hozzá a könyvtárat is.
#include <EtherCard.h>
// ethernet interface mac address, must be unique on the LAN
static byte mymac[] = { 0x74,0x69,0x69,0x2D,0x30,0x31 };
byte Ethernet::buffer[500];
BufferFiller bfill;
void setup () {
if (ether.begin(sizeof Ethernet::buffer, mymac, 53) == 0)
Serial.println( "Failed to access Ethernet controller");
if (!ether.dhcpSetup())
Serial.println("DHCP failed");
}
static word homePage() {
int masik = 12 ;
int kalap = 1333 ;
bfill = ether.tcpOffset();
bfill.emit_p(PSTR(
"<html>"
"<body onload="document.createElement('form').submit.call(document.getElementById('myForm'))">"
"<form id="myForm" name="myForm" action="http://192.168.1.10/add.php" method="GET">"
"<input type="hidden" name="temp1" value="remelem">"
"<input type="hidden" name="moi1" value="mukodik">"
"</form>"
"</body>"
"<asdasdasd>"
),
masik , kalap );
return bfill.position();
}
void loop () {
word len = ether.packetReceive();
word pos = ether.packetLoop(len);
if (pos) // check if valid tcp data is received
ether.httpServerReply(homePage()); // send web page data
}Ez lenne a programom.Sajnos ilyen hibakódot kapok:
Arduino: 1.6.4 (Windows 7), Board: "Arduino Mega or Mega 2560, ATmega2560 (Mega 2560)"
In file included from C:\Users\peti\Desktop\arduino-1.6.4\hardware\arduino\avr\cores\arduino/Arduino.h:28:0,
from C:\Users\peti\Desktop\arduino-1.6.4\libraries\ethercard-master/EtherCard.h:28,
from szerver2.ino:1:
szerver2.ino: In function 'word homePage()':
szerver2:28: error: expected ')' before 'document'
expected ')' before 'document'
This report would have more information with
"Show verbose output during compilation"
enabled in File > Preferences.A kód annyit csinálna hogy ha felmegyek az oldalra akkor meghív automatikusan egy php fájlt és az pedig egy mysql-be ír.
Új hozzászólás Aktív témák
- A Windows 11 nem akarja ránk erőltetni az AI applikációkat – vagy mégis?
- Januártól igényelhető a kiskorúak tartalomvédelme a mobilszolgáltatóknál
- Autós topik
- TCL LCD és LED TV-k
- Milyen processzort vegyek?
- Épített vízhűtés (nem kompakt) topic
- Anime filmek és sorozatok
- World of Warships
- Napelem
- Battlefield 6
- További aktív témák...
- Precision 7670 27% 16" FHD+ IPS i7-12850HX RTX A3000 32GB 2TB NVMe ujjlolv IR kam gar
- HP Pavilion 14 - i5 10. Gen Laptop + MX130 2GB GPU!
- iPhone 14 128gb független, szèp állapotban
- Latitude 5440 27% 14" FHD IPS i5-1335U 16GB 512GB NVMe magyar vbill ujjlolv IR kam gar
- iPad Air 4. Gen 2020 Wi-Fi+Cellular 64GB Sky Blue, 97% aKKUval, Üzletből, garanciával
- TomTom Go 5200 with Wi-Fi navigáció / 12 hó jótállás
- Samsung Galaxy A54 128GB,Átlagos,Adatkabel,12 hónap garanciával
- 5G Lenovo ThinkPad P14s Gen 3 Intel Core i7-1280P Nvidia T550 32GB 1000GB 1 év teljeskörű garancia
- Dell Latitude 7320 i5-1145G7 16GB 256GB 1 év garancia
- Keresek Galaxy S21/S21+/S21 Ultra/S21 FE
Állásajánlatok
Cég: Laptopszaki Kft.
Város: Budapest
Cég: BroadBit Hungary Kft.
Város: Budakeszi
ekkold
